<html><head>
    <meta http-equiv="content-type" content="text/html; charset=UTF-8"><title>HingeJoint</title></head>
<body bgcolor="#EFF1F0" link="#3A3966" vlink="#000000" alink="#000000">
<font face="Verdana, sans-serif" size="2"><p align="center"><b><font size="4">HingeJoint()</font></b></p>
<p><b>语法</b></p><blockquote>

Result = <font color="#3A3966"><b>HingeJoint</b></font>(#Joint, EntityID, PivotX, PivotY, PivotZ, AxisX, AxisY, AxisZ, EntityID2, PivotX2, PivotY2, PivotZ2, AxisX2, AxisY2, AxisZ2)</blockquote>

</blockquote>
<b>概要</b><br><blockquote>



Creates a new hinge joint between the two given entities. Hinge can be used to simulate door, moving bridge etc. 

 

</blockquote><p><b>参数</b></p><blockquote>
<style type="text/css">
table.parameters { border-spacing: 0px; border-style: none; border-collapse: collapse; }
table.parameters td { border-width: 1px; padding: 6px; border-style: solid; border-color: gray; vertical-align: top; font-family:Arial; font-size:10pt; }
</style>
<table width="90%" class="parameters">
<tr><td width="10%"><i>#Joint</i></td>
<td width="90%"> 
The number to identify the new joint. <a href="../reference/purebasic_objects.html">#PB_Any</a> 可以用来自动生成这个编码. 

</td></tr>
<tr><td><i>EntityID</i></td>
<td> 
 
The first entity id associated to the joint. To get a valid entity id, use <a href="../entity/entityid.html">EntityID()</a>. 

 

</td></tr>
<tr><td><i>PivotX</i></td>
<td> 
 
The X coordinate of the pivot point for the joint. Relative to the center of the entity. 

 

</td></tr>
<tr><td><i>PivotY</i></td>
<td> 
 
The Y coordinate of the pivot point for the joint. Relative to the center of the entity. 

 

</td></tr>
<tr><td><i>PivotZ</i></td>
<td> 
 
The Z coordinate of the pivot point for the joint. Relative to the center of the entity. 

 

</td></tr>
<tr><td><i>AxisX</i></td>
<td> 
 
The X orientation of the axis for the joint. 

 

</td></tr>
<tr><td><i>AxisY</i></td>
<td> 
 
The Y orientation of the axis for the joint. 

 

</td></tr>
<tr><td><i>AxisZ</i></td>
<td> 
 
The Z orientation of the axis for the joint. 

 

</td></tr>
<tr><td><i>EntityID2</i></td>
<td> 
 
The second entity id associated to the joint. To get a valid entity id, use <a href="../entity/entityid.html">EntityID()</a>. 

 

</td></tr>
<tr><td><i>PivotX2</i></td>
<td> 
 
The X coordinate of the second pivot point for the joint. Relative to the center of the second entity. 

 

</td></tr>
<tr><td><i>PivotY2</i></td>
<td> 
 
The Y coordinate of the second pivot point for the joint. Relative to the center of the second entity. 

 

</td></tr>
<tr><td><i>PivotZ2</i></td>
<td> 
 
The Z coordinate of the second pivot point for the joint. Relative to the center of the second entity. 

 

</td></tr>
<tr><td><i>AxisX2</i></td>
<td> 
 
The X orientation of the axis for the joint. 

 

</td></tr>
<tr><td><i>AxisY2</i></td>
<td> 
 
The Y orientation of the axis for the joint. 

 

</td></tr>
<tr><td><i>AxisZ2</i></td>
<td> 
 
The Z orientation of the axis for the joint. 

 

</td></tr>
</table>
</blockquote><p><b>返回值</b></p><blockquote>



Returns zero if the joint can't be created. If <a href="../reference/purebasic_objects.html">#PB_Any</a> is used 
as '#Joint' parameter, the new joint number will be returned as 'Result'. 

 

</blockquote><p><b>备注</b></p><blockquote>

<a href="getjointattribute.html">GetJointAttribute()</a> and <a href="setjointattribute.html">SetJointAttribute()</a> can be used with the following attribute to change the joint behavior: 
 
<pre><font face="Courier New, Courier, mono"size="2">  <font color="#924B72">#PB_HingeJoint_LowerLimit</font> : Lower limit of the joint
  <font color="#924B72">#PB_HingeJoint_UpperLimit</font> : Upper limit of the joint
</font></pre>

</blockquote><p><b>参阅</b></p><blockquote>

<a href="freejoint.html">FreeJoint()</a>, <a href="getjointattribute.html">GetJointAttribute()</a>, <a href="setjointattribute.html">SetJointAttribute()</a>, <a href="enablehingejointangularmotor.html">EnableHingeJointAngularMotor()</a> 

</Blockquote><p><b>已支持操作系统 </b><Blockquote>所有</Blockquote></p><center>&lt;- <a href=getjointattribute.html>GetJointAttribute()</a> - <a href="index.html">Joint Index</a> - <a href="hingejointmotortarget.html">HingeJointMotorTarget()</a> -&gt;<br><br>

</body></html>